﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Interfaces;
using Collections;

namespace Controller
{
    public class VareController
    {

        public List<Ivare> HentAlleVarerTilOrdre(Iordre aktuelordre)
        {
            VareCollection vc = new VareCollection();
            List<Ivare> vareliste = vc.HentAlleVarerTilOrdre(aktuelordre);
            return vareliste;
        }

        public List<Ivare> HentAlleVarer()
        {
            VareCollection vc = new VareCollection();
            List<Ivare> vareListe = vc.HentAlleVarer();
            return vareListe;
        }
        public bool FindesKmVare(int kilometerantal)
        {
            bool resultat;
            VareCollection vc = new VareCollection();
            resultat = vc.FindesKmVare(kilometerantal);
            return resultat;
        }
        public void OpretKmVare(int km, int pris)
        {
            VareCollection vc = new VareCollection();
            vc.OpretKmVare(km, pris);
        }
        public int HentSidstIndsatteVare()
        {
            int varenr;
            VareCollection vc = new VareCollection();
            varenr = vc.HentSidstIndsatteVare();
            return varenr;
        }
        public int HentVareUdfraKm(int km)
        {
            int varenr;
            VareCollection vc = new VareCollection();
            varenr = vc.HentVareUdfraKm(km);
            return varenr;
        }
        public void OpretVare(string navn, string beskrivelse, int pris)
        {
            VareCollection vc = new VareCollection();
            vc.OpretVare(navn, beskrivelse, pris);
        }

    }
}
